<% /* $Id: settings.jsp 132 2011-08-26 10:23:42Z altdotua@gmail.com $ */ %>

<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>

<%@ include file="../header.jsp" %>

<form action="<%= Linker.link("contests") %>" method="post">
	<input type="hidden" name="id" value="<%= contest.getId() %>">
	<input type="hidden" name="action" value="customEdit">
	<input type="hidden" name="return" value="<%= requestUrl %>">
	<table>
		<tr>
			<td>Sid</td>
			<td><input type="text" value="<%= contest.getSid() %>" name="Sid" maxlength="40" size="40"></td>
			<td><input type="submit" value="Change" name="EditSid"></td>
		</tr>
		<tr>
			<td>Name</td>
			<td><input type="text" value="<%= contest.getName() %>" name="Name" maxlength="200" size="40"></td>
			<td><input type="submit" value="Change" name="EditName"></td>
		</tr>
		<tr>
			<td>ContestType</td>
			<td>
				<select name="ContestType">
					<option <%= contest.getContestType().equalsIgnoreCase("ioi") ? "selected=\"selected\"" : "" %>>ioi</option>
					<option <%= contest.getContestType().equalsIgnoreCase("acm") ? "selected=\"selected\"" : "" %>>acm</option>
				</select>
			</td>
			<td><input type="submit" value="Change" name="EditContestType"></td>
		</tr>
		<tr>
			<td>StartTime</td>
			<td><input type="text" value="<%= contest.getStartTime() %>" name="StartTime" maxlength="40" size="40"></td>
			<td><input type="submit" value="Change" name="EditStartTime"></td>
		</tr>
		<tr>
			<td>FinishTime</td>
			<td><input type="text" value="<%= contest.getFinishTime() %>" name="FinishTime" maxlength="40" size="40"></td>
			<td><input type="submit" value="Change" name="EditFinishTime"></td>
		</tr>
		<tr>
			<td>FreezeTime</td>
			<td><input type="text" value="<%= contest.getFreezeTime() %>" name="FreezeTime" maxlength="40" size="40"></td>
			<td><input type="submit" value="Change" name="EditFreezeTime"></td>
		</tr>
		<tr>
			<td>UnfreezeTime</td>
			<td><input type="text" value="<%= contest.getFreezeTime() %>" name="UnfreezeTime" maxlength="40" size="40"></td>
			<td><input type="submit" value="Change" name="EditUnfreezeTime"></td>
		</tr>
		<tr>
			<td>Languages</td>
			<td><input type="checkbox" name="AllowAllLanguages" <%= contest.getAllowAllLanguages() ? "checked=\"checked\"" : "" %> >AllowAllLanguages</td>
			<td><input type="submit" value="Change" name="EditAllowAllLanguages"></td>
		</tr>
		<tr>
			<td>Users</td>
			<td><input type="checkbox" name="AllowAllUsers" <%= contest.getAllowAllUsers() ? "checked=\"checked\"" : "" %> >AllowAllUsers</td>
			<td><input type="submit" value="Change" name="EditAllowAllUsers"></td>
		</tr>
		<tr>
			<td>FirstTestSubmissions</td>
			<td><input type="checkbox" name="AllowFirstTestOnly" <%= contest.getAllowFirstTestOnly() ? "checked=\"checked\"" : "" %> >AllowFirstTestOnly</td>
			<td><input type="submit" value="Change" name="EditAllowFirstTestOnly"></td>
		</tr>
		<tr>
			<td>Virtual</td>
			<td><input type="checkbox" name="Virtual" <%= contest.getVirtual() ? "checked=\"checked\"" : "" %> disabled="disabled" >Virtual</td>
			<td><input type="submit" value="Change" name="EditVirtual"></td>
		</tr>
		<tr>
			<td>Duration</td>
			<td><input type="text" value="<%= contest.getContestDuration() %>" name="Duration" maxlength="20" size="20"></td>
			<td><input type="submit" value="Change" name="EditDuration"></td>
		</tr>
		<tr>
			<td>ShowFullMonitor</td>
			<td><input type="checkbox" name="ShowFullMonitor" <%= contest.getShowFullMonitor() ? "checked=\"checked\"" : "" %> >ShowFullMonitor</td>
			<td><input type="submit" value="Change" name="EditShowFullMonitor"></td>
		</tr>
		<tr>
			<td>ShowFullSubmissions</td>
			<td><input type="checkbox" name="ShowFullSubmissions" <%= contest.getShowFullSubmissions() ? "checked=\"checked\"" : "" %> >ShowFullSubmissions</td>
			<td><input type="submit" value="Change" name="EditShowFullSubmissions"></td>
		</tr>
		<tr>
			<td>ShowWrongTest</td>
			<td><input type="checkbox" name="ShowWrongTest" <%= contest.getShowWrongTest() ? "checked=\"checked\"" : "" %> >ShowWrongTest</td>
			<td><input type="submit" value="Change" name="EditShowWrongTest"></td>
		</tr>
		<tr>
			<td>ShowMaxTime</td>
			<td><input type="checkbox" name="ShowMaxTime" <%= contest.getShowMaxTime() ? "checked=\"checked\"" : "" %> >ShowMaxTime</td>
			<td><input type="submit" value="Change" name="EditShowMaxTime"></td>
		</tr>
		<tr>
			<td>ShowMaxMemory</td>
			<td><input type="checkbox" name="ShowMaxMemory" <%= contest.getShowMaxMemory() ? "checked=\"checked\"" : "" %> >ShowMaxMemory</td>
			<td><input type="submit" value="Change" name="EditShowMaxMemory"></td>
		</tr>
		<tr>
			<td>ShowTestingDetails</td>
			<td><input type="checkbox" name="ShowTestingDetails" <%= contest.getShowTestingDetails() ? "checked=\"checked\"" : "" %> >ShowTestingDetails</td>
			<td><input type="submit" value="Change" name="EditShowTestingDetails"></td>
		</tr>
		<tr>
			<td>ShowScore</td>
			<td><input type="checkbox" name="ShowScore" <%= contest.getShowScore() ? "checked=\"checked\"" : "" %> >ShowScore</td>
			<td><input type="submit" value="Change" name="EditShowScore"></td>
		</tr>
		<tr>
			<td>StatementsLink</td>
			<td><input type="text" value="<%= contest.getStatementsLink() %>" name="StatementsLink" maxlength="200" size="40"></td>
			<td><input type="submit" value="Change" name="EditStatementsLink"></td>
		</tr>
	</table>
	<input type="submit" value="Change all fields" name="EditAll">
</form>

<%@ include file="../footer.jsp" %>